package com.bestcem.xm.om.controller.param;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 短信邮件明细分页接口--前端传入
 *
 * @author zq.ding <zq.ding@idiaoyan.com>
 * @version v1.0
 * @date 2021/11/17 10:29
 */
@AllArgsConstructor
@Data
public class MessageParam {

    @JsonProperty("org_name")
    private String orgName;
    @JsonProperty("org_code")
    private String orgCode;
    @JsonProperty("contact")
    private String contact;
    @JsonProperty("topic")
    private String topic;
    @JsonProperty("seq")
    private String seq;
    @JsonProperty("page")
    private Integer page;
    @JsonProperty("size")
    private Integer size;
    @JsonProperty("start_send_time")
    @JsonFormat(pattern = "yyyy/MM/dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime startSendTime;
    @JsonProperty("end_send_time")
    @JsonFormat(pattern = "yyyy/MM/dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime endSendTime;
    private Integer offset;

    public MessageParam(String orgName, String orgCode, String contact, String topic, String seq, Integer page, Integer size, LocalDateTime startSendTime, LocalDateTime endSendTime) {
        this.orgName = orgName;
        this.orgCode = orgCode;
        this.contact = contact;
        this.topic = topic;
        this.seq = seq;
        this.page = page;
        this.size = size;
        this.startSendTime = startSendTime;
        this.endSendTime = endSendTime;
    }

    public MessageParam() {
    }
}
